package cn.gok.mmall.common;

/**
 * @Author: chenfan
 * @Description: 专门用来存放响应状态值的枚举工具类
 */
public enum ResponseCode {

    SUCCESS(0,"SUCCESS"),
    ERROR(1,"ERROR"),
    NEED_LOGIN(10,"NEED_LOGIN");

    //状态码
    private final int code;
    //对当前状态码的描述
    private final String desc;

    ResponseCode(int code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public int getCode() {
        return code;
    }

    public String getDesc() {
        return desc;
    }
}
